package com.testing.webPO;

import com.testing.web.WebKeyword;
import org.testng.annotations.AfterClass;
import org.testng.annotations.BeforeClass;
import org.testng.annotations.Parameters;
import org.testng.annotations.Test;

/**
 * @Classname ShopAdminLoginNG
 * @Description 类型说明
 * @Date 2022/7/5 21:50
 * @Created by 特斯汀Roy
 */
public class ShopAdminLoginNG extends WebKeyword {

    //属性
    private String url="http://www.testingedu.com.cn:8000/Admin/Admin/login";

    @BeforeClass
    public void init(){
        openBrowser("chrome");
        visitWeb(url);
        setWindowSize(300,1600,1000);
    }

    @Test
    @Parameters({"password"})

    public  void login(String password) {
        input("//input[@name='username']","admin");
        input("//input[@name='password']",password);
        input("//input[@name='vertify']","1");
        click("//input[@value='登录']");
    }

}
